#llmAnswer.py
from sqlalchemy import Column, ForeignKey, String, Integer
from app.models.base import Base
from flask_sqlalchemy import SQLAlchemy
#from app.models.assignqV import AssignqVariation
db = SQLAlchemy()
class Medicine(Base):
    M_id = Column(Integer, primary_key=True)
    Medicine_Name = Column(String(20), nullable=False)
    Medicine_Category = Column(String(1000), nullable=False)
    Medicine_picture = Column(String(1000), nullable=False)
    Price = Column(Integer, nullable=False)
    S_id = Column(Integer, nullable=True)#外键 药材供应商表
    I_picture = Column(String(1000), nullable=False)#外键 药材使用说明表
    
    def __init__(self, M_id, Medicine_Name,Medicine_picture, Medicine_Category, Price, S_id, I_picture ):
        super(Medicine, self).__init__()
        self.M_id = M_id
        self.Medicine_Name = Medicine_Name
        self.Medicine_Category = Medicine_Category
        self.Medicine_picture = Medicine_picture
        self.Price = Price
        self.S_id = S_id
        self.I_picture = I_picture
        